package com.github.shuaidd.rest.runtime;

import org.activiti.app.model.runtime.CreateProcessInstanceRepresentation;
import org.activiti.app.model.runtime.ProcessInstanceRepresentation;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("app")
public class ProcessInstancesResource extends AbstractProcessInstancesResource {

    @Override
    @RequestMapping(value = "/rest/process-instances", method = RequestMethod.POST)
    public ProcessInstanceRepresentation startNewProcessInstance(@RequestBody CreateProcessInstanceRepresentation startRequest) {
        return super.startNewProcessInstance(startRequest);
    }
}
